import store from "./calculatorStore"

// 此处为加减乘除功能区

class ActionHelper {
    
     plus (val:number): any{

        store.state.calResult +=val;
        store.state.operator = '';
        return ;
        
     }

     sub (val:number): any{

        store.state.calResult -=val;
        store.state.operator = '';
        return ;
     }

     mul (val:number): any{

        store.state.calResult *=val;
        store.state.operator = '';
        return ;
     }
     
     chu (val:number): any{

        store.state.calResult /=val;
        store.state.operator = '';
        return ;
     } 
     
}

export default ActionHelper;